<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
<head>
<audio src="dream.mp3" autoplay="autoplay"></audio>
    <title>Welcome!</title>
<style>

body {
    width: 600px;
    margin: 40px auto;
    font-family: 'trebuchet MS', 'Lucida sans', Arial;
    font-size: 14px;
    color: #444;
}

table {
    *border-collapse: collapse; /* IE7 and lower */
    border-spacing: 0;
    width: 100%;    
}

.bordered {
    border: solid #ccc 1px;
    -moz-border-radius: 6px;
    -webkit-border-radius: 6px;
    border-radius: 6px;
    -webkit-box-shadow: 0 1px 1px #ccc; 
    -moz-box-shadow: 0 1px 1px #ccc; 
    box-shadow: 0 1px 1px #ccc;         
}

.bordered tr:hover {
    background: #fbf8e9;
    -o-transition: all 0.1s ease-in-out;
    -webkit-transition: all 0.1s ease-in-out;
    -moz-transition: all 0.1s ease-in-out;
    -ms-transition: all 0.1s ease-in-out;
    transition: all 0.1s ease-in-out;     
}    
    
.bordered td, .bordered th {
    border-left: 1px solid #ccc;
    border-top: 1px solid #ccc;
    padding: 10px;
    text-align: left;    
}

.bordered th {
    background-color: #dce9f9;
    background-image: -webkit-gradient(linear, left top, left bottom, from(#ebf3fc), to(#dce9f9));
    background-image: -webkit-linear-gradient(top, #ebf3fc, #dce9f9);
    background-image:    -moz-linear-gradient(top, #ebf3fc, #dce9f9);
    background-image:     -ms-linear-gradient(top, #ebf3fc, #dce9f9);
    background-image:      -o-linear-gradient(top, #ebf3fc, #dce9f9);
    background-image:         linear-gradient(top, #ebf3fc, #dce9f9);
    -webkit-box-shadow: 0 1px 0 rgba(255,255,255,.8) inset; 
    -moz-box-shadow:0 1px 0 rgba(255,255,255,.8) inset;  
    box-shadow: 0 1px 0 rgba(255,255,255,.8) inset;        
    border-top: none;
    text-shadow: 0 1px 0 rgba(255,255,255,.5); 
}

.bordered td:first-child, .bordered th:first-child {
    border-left: none;
}

.bordered th:first-child {
    -moz-border-radius: 6px 0 0 0;
    -webkit-border-radius: 6px 0 0 0;
    border-radius: 6px 0 0 0;
}

.bordered th:last-child {
    -moz-border-radius: 0 6px 0 0;
    -webkit-border-radius: 0 6px 0 0;
    border-radius: 0 6px 0 0;
}

.bordered th:only-child{
    -moz-border-radius: 6px 6px 0 0;
    -webkit-border-radius: 6px 6px 0 0;
    border-radius: 6px 6px 0 0;
}

.bordered tr:last-child td:first-child {
    -moz-border-radius: 0 0 0 6px;
    -webkit-border-radius: 0 0 0 6px;
    border-radius: 0 0 0 6px;
}

.bordered tr:last-child td:last-child {
    -moz-border-radius: 0 0 6px 0;
    -webkit-border-radius: 0 0 6px 0;
    border-radius: 0 0 6px 0;
}



/*----------------------*/

.zebra td, .zebra th {
    padding: 10px;
    border-bottom: 1px solid #f2f2f2;    
}

.zebra tbody tr:nth-child(even) {
    background: #f5f5f5;
    -webkit-box-shadow: 0 1px 0 rgba(255,255,255,.8) inset; 
    -moz-box-shadow:0 1px 0 rgba(255,255,255,.8) inset;  
    box-shadow: 0 1px 0 rgba(255,255,255,.8) inset;        
}

.zebra th {
    text-align: left;
    text-shadow: 0 1px 0 rgba(255,255,255,.5); 
    border-bottom: 1px solid #ccc;
    background-color: #eee;
    background-image: -webkit-gradient(linear, left top, left bottom, from(#f5f5f5), to(#eee));
    background-image: -webkit-linear-gradient(top, #f5f5f5, #eee);
    background-image:    -moz-linear-gradient(top, #f5f5f5, #eee);
    background-image:     -ms-linear-gradient(top, #f5f5f5, #eee);
    background-image:      -o-linear-gradient(top, #f5f5f5, #eee); 
    background-image:         linear-gradient(top, #f5f5f5, #eee);
}

.zebra th:first-child {
    -moz-border-radius: 6px 0 0 0;
    -webkit-border-radius: 6px 0 0 0;
    border-radius: 6px 0 0 0;  
}

.zebra th:last-child {
    -moz-border-radius: 0 6px 0 0;
    -webkit-border-radius: 0 6px 0 0;
    border-radius: 0 6px 0 0;
}

.zebra th:only-child{
    -moz-border-radius: 6px 6px 0 0;
    -webkit-border-radius: 6px 6px 0 0;
    border-radius: 6px 6px 0 0;
}

.zebra tfoot td {
    border-bottom: 0;
    border-top: 1px solid #fff;
    background-color: #f1f1f1;  
}

.zebra tfoot td:first-child {
    -moz-border-radius: 0 0 0 6px;
    -webkit-border-radius: 0 0 0 6px;
    border-radius: 0 0 0 6px;
}

.zebra tfoot td:last-child {
    -moz-border-radius: 0 0 6px 0;
    -webkit-border-radius: 0 0 6px 0;
    border-radius: 0 0 6px 0;
}

.zebra tfoot td:only-child{
    -moz-border-radius: 0 0 6px 6px;
    -webkit-border-radius: 0 0 6px 6px
    border-radius: 0 0 6px 6px
}
  
</style>
</head>

<body background = "img/5.jpg">

<h2>欢迎来到组员管理系统:欢迎回归主页！&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp&nbsp<a href="back.jsp">退出系统</a></h2>
<table class="bordered">
<form name="bookFrom" action="addBook" method="post">
	姓名：<input name="name" type="text"/><br/>
	学号：<input name="num" type="text"/><br/>
	电话：<input name="tel" type="text"/><br/>
	<input type="submit" value="修改我的信息" />

</form></br></br></br>
    <thead>
    <tr>
        <th>编号</th>        
        <th>姓名</th>
        <th>学号</th>
        <th>电话</th>
        <th>类型</th>
        <th>小组</th>
    </tr>
    </thead>
    <c:forEach items="${user}" var="u">
<tr
bgcolor="#FFFFFF"
onMouseMove="javascript:this.bgColor='#00FFCC';"
onMouseOut="javascript:this.bgColor='#FFFFFF';"

>
<td>${u.id}</td>
<td>${u.name}</td>
<td>${u.num}</td>
<td>${u.tel}</td>
<td>${u.type}</td>
<td>${u.group}</td>
<td><a href="user?type=del&uid=${u.id}" onclick="return confirm('确认退出？');">退出该组</a></td>
</tr>
</c:forEach> 
</table>
<br><br>

<h2>申请加入其他小组信息</h2>
<table class="zebra">
<form name="bookFrom" action="findGroup" method="post">
  <input type="search" name="user_search" placeholder="search" />
  <input type="submit" />
</form></br></br></br>
    <thead>
    <tr>
        <th>组号</th>        
        <th>组名</th>
        <th>组长</th>
        <th>简介</th>
        <th>申请加入</th>
    </tr>
    </thead>  
    <c:forEach items="${groups}" var="u">
<tr
bgcolor="#FFFFFF"
onMouseMove="javascript:this.bgColor='#00FFCC';"
onMouseOut="javascript:this.bgColor='#FFFFFF';"

>
<td>${u.id}</td>
<td>${u.name}</td>
<td>${u.leader}</td>
<td>${u.introduction}</td>
<td><a href="user?type=toedit&uid=${u.id}">申请加入</a></td>
</tr>
</c:forEach>      
    
</table>
</br></br></br>
<div>
	<a href="BookShow?curPage=1">首页</a>
	<c:choose>
		<c:when test="${page.curPage==1 }">
			<a href="BookShow?curPage=${page.curPage }">上一页</a>
		</c:when>
		<c:otherwise>
			<a href="BookShow?curPage=${page.curPage-1 }">上一页</a>
		</c:otherwise>
	</c:choose>
	<c:choose>
		<c:when test="${page.curPage==page.totalPageCount }">
			<a href="BookShow?curPage=${page.curPage }">下一页</a>
		</c:when>
		<c:otherwise>
			<a href="BookShow?curPage=${page.curPage+1 }">下一页</a>
		</c:otherwise>
	</c:choose>
	<a href="BookShow?curPage=${page.totalPageCount }">尾页</a>
</div>
<br>
    

</body>
</html>